package com.xique.blelock.view.DeviceManager;

import android.annotation.SuppressLint;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.view.View;
import android.widget.Button;
import android.widget.ImageView;
import android.widget.TextView;

import com.xique.blelock.R;


public class Reassembl_Activity extends Activity implements View.OnClickListener {
    private ImageView xiansiview;
    private TextView zghanwushebei,Mgoadd;
    private Button chongxin;
    @Override
    protected void onCreate(@Nullable Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.zhuyeactivity );
        initview();
    }

    @SuppressLint("WrongViewCast")
    private void initview() {
        zghanwushebei = findViewById(R.id.zghanwushebei);
        Mgoadd = findViewById(R.id.goadd);
        xiansiview = findViewById(R.id.devices);
        chongxin = findViewById(R.id.aadddevice);
        chongxin.setOnClickListener(this);

    }

    public Reassembl_Activity() {
        super();
    }

    @Override
    protected void onStart() {
        super.onStart();
    }

    @Override
    protected void onRestart() {
        super.onRestart();
    }

    @Override
    public void onStateNotSaved() {
        super.onStateNotSaved();
    }

    @Override
    protected void onResume() {
        super.onResume();
        xiansiview.setImageResource(R.drawable.u163);//不会变形
        zghanwushebei.setText("附近暂无可用设备");
        Mgoadd.setText("再重新搜索一下吧");
        chongxin.setBackgroundColor(R.drawable.blue_spapes);
        chongxin.setText("重新搜索");
    }

    @Override
    protected void onPostResume() {
        super.onPostResume();
    }

    @Override
    public void onClick(View v) {
        Intent serverIntent = new Intent(this, Adddevice_Activity.class); // 跳设备添加界面
        startActivity(serverIntent);
    }
}
